package com.ymttest.database.sqlwapper.godmch;

import java.util.List;

import com.ymt.database.SqlManager;
import com.ymttest.database.model.godmch.markup_config_agent_price;
import com.ymttest.database.model.godmch.markup_config_agent_priceExample;
import com.ymttest.utils.EnvSetup;

public class markup_config_agent_priceWapper {
	SqlManager manage;
	public markup_config_agent_priceWapper() {
		manage = new SqlManager("mysqlgodmchdb" + EnvSetup.getEnv());
		 
	}
	
	public  List<markup_config_agent_price> selectByExample(markup_config_agent_priceExample example) throws InterruptedException {
		List<markup_config_agent_price> list = manage.getSelectResults("com.ymttest.database.mapping.godmch.markup_config_agent_priceMapper.selectByExample",example);
		manage.commit();
		return list;
	}
	
	public  markup_config_agent_price selectByPrimaryKey(Integer agentType) throws InterruptedException {	
		markup_config_agent_price model=new markup_config_agent_price();
		List<markup_config_agent_price> lst = manage.getSelectResults("com.ymttest.database.mapping.godmch.markup_config_agent_priceMapper.selectByPrimaryKey",agentType);
		if(lst.size()>0)
			 model=lst.get(0);
		manage.commit();
		return model;
	}
	
	
	public  Integer updateByPrimaryKey(markup_config_agent_price record) throws InterruptedException {	

		Integer result= manage.update("com.ymttest.database.mapping.godmch.markup_config_agent_priceMapper.updateByPrimaryKey",record);

		manage.commit();
		return result;
	}
	
	public static void main(String args[]) {
	  
	}
}
